/* Copyright 2019 The TensorFlow Authors. All Rights Reserved.

Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at

    http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
==============================================================================*/
:host {
  align-items: center;
  display: flex;
  flex: 1 1 auto;
  font-size: 14px;
  height: 100%;
  overflow: hidden;
}

mat-form-field {
  flex: 0 0;
  /* visually center align with _text_ of the select to the center. */
  margin-top: 5px;
  /* default width is 180px */
  width: 130px;
}

mat-label,
mat-select,
mat-option {
  font-weight: 500;
  text-transform: uppercase;
}

.active-plugin-list {
  align-self: stretch;
  flex: 1 1 auto;
  overflow: hidden;
}

.plugin-name {
  align-items: center;
  display: inline-flex;
  height: 100%;
  justify-content: center;
  padding: 0 12px;
  width: 100%;
}

:host ::ng-deep .active-plugin-list {
  // Override mat-tab styling. By default, mat-tab has the right styling but,
  // here, we are using it under dark header background. Must invert the color.

  &.mat-primary .mat-ink-bar {
    background-color: currentColor;
  }

  .mat-tab-label,
  .mat-tab-link {
    // Inherit from `color` on the toolbar.
    color: inherit;
    // default is .6 and it is too dark against dark background.
    opacity: 0.7;

    &.mat-tab-label-active {
      opacity: 1;
    }
  }

  .mat-tab-header-pagination-chevron {
    border-color: currentColor;
  }

  .mat-tab-header-pagination-disabled {
    visibility: hidden;
  }

  .mat-tab-disabled {
    display: none;
  }

  .mat-tab-header,
  .mat-tab-labels,
  .mat-tab-label {
    height: 100%;
  }

  .mat-tab-label {
    min-width: 48px; /* default is 160px which is too big for us */
    padding: 0; /* default is 24px */
    text-transform: uppercase;
  }

  .mat-tab-label-content {
    height: 100%;
  }

  mat-tab-header:not(.mat-tab-header-pagination-controls-enabled) {
    padding: 0 36px;
  }
}
